/**
 * 
 */
package com.jushu.storbox.service;

import java.util.List;

import android.content.Context;

import com.jushu.storbox.entities.FileFolderInfo;
import com.huawei.sharedrive.sdk.android.exception.ClientException;
import com.huawei.sharedrive.sdk.android.model.request.FolderBaseRequest;
import com.huawei.sharedrive.sdk.android.model.request.FolderCreateRequest;
import com.huawei.sharedrive.sdk.android.modelV2.request.FolderCopyRequstV2;
import com.huawei.sharedrive.sdk.android.modelV2.request.FolderSearchRequestV2;
import com.huawei.sharedrive.sdk.android.modelV2.request.LinkCreateRequestV2;
import com.huawei.sharedrive.sdk.android.modelV2.response.FolderListResponseV2;
import com.huawei.sharedrive.sdk.android.modelV2.response.FolderResponse;
import com.huawei.sharedrive.sdk.android.modelV2.response.LinkInfoV2;
import com.huawei.sharedrive.sdk.android.modelV3.response.LinkInfoV3;
import com.huawei.sharedrive.sdk.android.service.handler.AsyncTaskHandler;

public interface IRemoteFolderService {
	
	public FolderResponse getFolderResponse(String ownerId, String folderId) throws ClientException;
	
	/**
	 * @param folderID
	 * @param des
	 * @param limit
	 * @param offset
	 * @param orderby
	 * @return
	 * @throws ClientException
	 */
	public FolderListResponseV2 getFolderListResponse(String folderID, String des, int limit,
			int offset, String orderby) throws ClientException ;
	
	
	/**
	 * @param context
	 * @param folderID
	 * @param des
	 * @param limit
	 * @param offset
	 * @param orderby
	 * @return
	 * @throws ClientException
	 */
	public List<FileFolderInfo> getFolderList(Context context, String folderID, String des, int limit,
			int offset, String orderby) throws ClientException ;
	/**
	 * @param folderID
	 * @param newFolderName
	 * @return
	 * @throws ClientException
	 */
	public FolderResponse renameFolder(FileFolderInfo fileInformation, String newFolderName) throws ClientException;

	/**
	 * @param request
	 * @param name
	 * @return
	 * @throws ClientException
	 */
	public FolderResponse renameFolderInfo(FolderBaseRequest request, String name) throws ClientException;

	/**
	 * @param folderID
	 * @return
	 */
	public String deleteFolder(String ownerId, String folderID) throws ClientException;
	/**
	 * 
	 * @param FolderBaseRequest
	 * @return
	 */
	public String deleteFolder(FileFolderInfo fileFolderInfo) throws ClientException;

	
	public void deleteFolderAsyn(FileFolderInfo fileFolderInfomation, AsyncTaskHandler handler) throws ClientException;
	/**
	 * 
	 * @param request
	 * @return
	 */
	public FileFolderInfo createFolder(Context context, String ownerId, FolderCreateRequest request) throws ClientException;

	/**
	 * 
	 * @param folderID
	 * @param request
	 * @return
	 */
	public FolderResponse moveFolder(FileFolderInfo fileFolderInfo, FileFolderInfo targetFolder) throws ClientException;

	/**
	 * @param ownerId
	 * @param folderID
	 * @param request
	 * @return
	 * @throws ClientException
	 */
	public FolderResponse copyFolder(String ownerId, String folderID, FolderCopyRequstV2 request) throws ClientException;
	
	/**
	 * @param context
	 * @param folderId
	 * @return
	 * @throws ClientException 
	 */
	public boolean isUpdate(Context context, FileFolderInfo info) throws ClientException;

	/**
	 * 
	 * @param request
	 *
	 * @return FolderResponse
	 * @throws ClientException
	 */
	public FolderListResponseV2 searchFolder(FolderSearchRequestV2 request) throws ClientException;
	
	/**
     * @throws ClientException
     */
	public List<LinkInfoV3> getLink(FileFolderInfo fileInformation) throws ClientException;
	
	/**
	 * @param authorization
	 * @return
	 * @throws ClientException
	 */
	public boolean isComplexLinkCode(String authorization) throws ClientException;
	
	/**
	 * @param nodeID
	 * @throws ClientException
	 */
	public void deleteLink(FileFolderInfo fileInformation,String linkCode) throws ClientException;
	
	/**
     * 
     * @param nodeID      
     *
     * @return LinkInfoV3
     * @throws ClientException
     */
	public LinkInfoV3 createLink(FileFolderInfo fileInformation) throws ClientException;
	
	/**
	 * @param nodeID
	 * @param linkRequest
	 * @return
	 * @throws ClientException
	 */
	public LinkInfoV3 updateLink(FileFolderInfo fileInformation, LinkCreateRequestV2 linkRequest) throws ClientException;
	
}
